<div style="padding: 30px;" class="layui-form layui-form-pane"> <!-- 提示：如果你不想用form，你可以换成div等任何一个普通元素 -->

    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 房间编号：</label>
        <div class="layui-input-inline" id="room_view">
            <select name="room_id" >
                <option value="">请选择房间</option>
                {if condition="count($brandList)>0"}
                {volist name="brandList" id="vo"}
                <option value="{$vo.id}">{$vo.bn}</option>
                {/volist}
                {/if}
            </select>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 预留姓名：</label>
        <div class="layui-input-inline seller-inline-4">
            <input type="text" name="name" required lay-verify="required" placeholder="请输入预留姓名" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 预留电话：</label>
        <div class="layui-input-inline seller-inline-4">
            <input type="text" name="mobile" required lay-verify="required" placeholder="请输入预留电话" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 预留类型：</label>
        <div class="layui-input-inline seller-inline-4">
            <select name="type" lay-verify="">
                <option value="2">挂单</option>
                <option value="3">招待</option>
            </select>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 预留日期：</label>
        <div class="layui-input-inline seller-inline-4">
            <input type="text" id="booking_time" name="booking_time" lay-verify="required" placeholder="请选择时间" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 到店时间：</label>
        <div class="layui-input-inline seller-inline-4">
            <input type="text" id="come_time" name="come_time" placeholder="请选择时间" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label"><i class="required-color">*</i> 备注：</label>
        <div class="layui-input-inline seller-inline-4">
            <input type="text" name="memo" required placeholder="请输入简单备注" autocomplete="off" class="layui-input">
        </div>
    </div>

    <button class="layui-btn layui-btn-fluid save-brand" lay-submit lay-filter="add-booking">保存</button>

</div>

<script id="bn_tpl" type="text/html">
    <select name="room_id">
        <option value="">请选择房间</option>
        {{#  layui.each(d.list, function(index, item){ }}
        <option value="{{ item.id }}">{{ item.bn }}</option>
        {{#  }); }}
    </select>
</script>

<script>
    layui.use(['table','form','layer','laydate','laytpl'],function(){
        var date = layui.laydate;
        var laytpl = layui.laytpl;
        JsGet("{:url('review/getAll')}", function(e){
            if(e.data.length>0){
                var getTpl = bn_tpl.innerHTML
                    ,view = document.getElementById('room_view');
                var tmpData = {};
                tmpData.list = e.data;
                laytpl(getTpl).render(tmpData, function(html){
                    view.innerHTML = html;
                });
                layui.form.render();
            }
        })
        date.render({
            elem:'#booking_time'
        });
        date.render({
            elem:'#come_time'
        });
        layui.form.render();

    });
</script>